using System;
using System.Collections.Generic;
using System.Text;
using System.Data.Common;
using System.Data;
using XBLib.Dal.AdoDal;
using DataInfo;
namespace KenLib.Dal
{
    public class 本人住所情報Dao : BaseAdoDao
      {
        public int Ins_Upd本人住所情報(本人住所情報 info, string strColumnsName)
        {
            List<DbParameter> lsParam = new GlobalDao().CreateArrayParam(info, strColumnsName);
            DbParameter paramID = _daoHelper.CreateParameter("@ID", info.ID, DbType.Int32, ParameterDirection.InputOutput);
            lsParam.Add(paramID);
            DbCommand command = _daoHelper.CreateCommand(CommandNameManager.INS_UPD_本人住所情報, CommandType.StoredProcedure, lsParam.ToArray());
            int iExe = _daoHelper.Execute(command);
            return Convert.ToInt32(paramID.Value);
        }

          #region TUNG

        public DataTable grv_本人住所(int 社員ID)
        {
            DbParameter param1 = _daoHelper.CreateParameter("@社員ID", 社員ID, DbType.Int32);
            DbCommand command = _daoHelper.CreateCommand("sp_grv_本人住所_TUNG", CommandType.StoredProcedure, param1);
            return _daoHelper.Query(command); 
        }

        public DataTable Select本人住所情報(int 社員ID)
        {
            DbParameter param1 = _daoHelper.CreateParameter("@社員ID", 社員ID, DbType.Int32);
            DbCommand command = _daoHelper.CreateCommand("sp_Select本人住所情報_TUNG", CommandType.StoredProcedure, param1);
            return _daoHelper.Query(command); 
        }
          #endregion
      }
}
